package TCPTest05;

import TCPTest06.MyRunnable;

import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;

public class Server {

    public static void main(String[] args) throws IOException {
        ServerSocket ss = new ServerSocket(10000);

        while (true) {
            //等待客户端端连接
            Socket s =  ss.accept();
            //开启一条线程，
            // 一个用户对应一个线程，
            new Thread(new MyRunnable(s)).run();
        }

    }
}
